package com.hifar.test.entrust.pojo;

import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.hifar.model.BaseModel;
import com.hifar.plat.AopOption.Dict;
import com.hifar.plat.AopOption.Excel;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.util.Date;

/**
* <p>
 * 委托单
 * </p>
 *
 * @author wei
 * @since 2024-12-04 15:51:56
 */
@Data
@TableName("hf_env_entrust")
@ApiModel(value = "HfEnvEntrust对象", description = "委托单")
public class HfEnvEntrust extends BaseModel implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 委托单号
     */
    @Excel(name = "委托单号", sort = 1)
    @ApiModelProperty(value = "委托单号")
    private String entrustCode;


    @ApiModelProperty(value = "委托日期")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @NotNull(message = "委托时间不能为空!")
    private Date entrustTime;


    /**
     * 委托部门
     */
    @Excel(name = "委托部门", sort = 3)
    @ApiModelProperty(value = "委托部门")
    @NotEmpty(message = "委托部门不能为空!")
    private String entrustCust;

    /**
     * 委托部门
     */
    @ApiModelProperty(value = "委托部门")
    @NotEmpty(message = "委托部门不能为空!")
    private String entrustCustId;


    /**
     * 委托人id
     */
    @ApiModelProperty(value = "委托人id")
    private String entrustUserId;

    /**
     * 流程id
     */
    @ApiModelProperty(value = "流程id")
    @JSONField(name = "flowId")
    private String flowId;

    @Excel(name = "委托人", sort = 4)
    @ApiModelProperty(value = "委托人姓名")
    private String entrustUserName;


    @Excel(name = "联系方式", sort = 5)
    @ApiModelProperty(value = "委托人联系方式")
    private String entrustUserPhone;

    @Excel(name = "课题名称", sort = 6)
    @ApiModelProperty(value = "课题名称")
    private String subjectName;

    @Excel(name = "课题编号", sort = 7)
    @ApiModelProperty(value = "课题编号")
    private String subjectNo;


    @Excel(name = "样品数量", sort = 8)
    @ApiModelProperty(value = "样品数量")
    private String productNum;


    @Excel(name = "期望完成日期", sort = 6, format = "yyyy-MM-dd")
    @ApiModelProperty(value = "期望完成日期")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date predictFinishTime;

    /**
     * 试验性质编码
     */
    @Excel(name = "试验性质", dictCode = "hf_env_test_property", sort = 7)
    @ApiModelProperty(value = "试验性质编码")
    @Dict(dictCode = "hf_env_test_property")
    @NotEmpty(message = "试验性质编码不能为空!")
    private String testPropertyCode;


    @ApiModelProperty("项目介绍")
    private String remarks;

    @ApiModelProperty("二维码路径")
    private String qrPdfPath;

    @ApiModelProperty("工控委托id")
    private String gkEntrustId;

    @ApiModelProperty("数据包文件路径")
    private String dataPackagePath;

    @ApiModelProperty("数据来源")
    private String dataSource;

    @ApiModelProperty("项目类型编码")
    private String unitTypeCode;

    @ApiModelProperty("项目类型名称")
    private String unitTypeName;

}
